package com.ruoyi.danny.controller;

import org.activiti.engine.ActivitiException;

public class CustomActivi7Exception extends ActivitiException {
    private static final long serialVersionUID = 1L;
    protected String className;

    public CustomActivi7Exception(String className, Throwable cause) {
        super(getExceptionMessageMessage(className, cause), cause);
        this.className = className;
    }

    public String getClassName() {
        return this.className;
    }

    private static String getExceptionMessageMessage(String className, Throwable cause) {
        return cause instanceof ClassNotFoundException ? "Class not found: " + className : "Could not load class: " + className;
    }
}
